import fetch from '@/common/utils/http'

export interface QueryParams {
  pageSize: number
  name?: string
  page: number
  status?: '' | 'disable' | 'enable'
}

export interface UpdateParams {
  status: '' | 'disable' | 'enable'
  name: string
  number: string
}
export interface AddParams {
  status: '' | 'disable' | 'enable'
  name: string
}
export const fetchData = (data:any) =>
  fetch({
    url: '/call/web/phone/bar/list',
    method: 'POST',
    data:data
  })

export const clientAddSave = (data: any) =>
  fetch({
    url: '/call/web/phone/bar/create',
    method: 'POST',
    data
  })
export const clientUpdateSave = (data: any) =>
  fetch({
    url: '/call/web/phone/bar/update',
    method: 'POST',
    data
  })

export const clientDelete = (data: { number: string }) =>
  fetch({
    url: '/call/web/phone/bar/delete',
    method: 'POST',
    data
  })


